{%extends "base.html"%}
{%block body%}
<script type="text/javascript">
	
	$(document).ready(function(){
		$("#formEdit").validate({
			rules:{
				"name": "email required"
				,"password": "required"
				,"expire_date": "date required"
			}
		});
		$('#status').val({{item.status}});
	});
		
</script>
<table cellpadding="2" width="100%" class="smallfont" border="0">
  <tr>
  	<td class="errorlist" >{{err}}</td>
  </tr>
</table> 
<form name="formEdit" id="formEdit" action="" method="post" onsubmit="OnSubmit();">
<table border="0" cellpadding="5" cellspacing="0" width=600>
<tr >
	<th width="100">Email</th>
	<td><input name="name" id="name" type="text" size="30" value="{{item.name}}" ></td>
</tr>
<tr >
	<th>Password</th>
	<td><input name="password" id="password" type="password" size="30" value="{{item.password}}" ></td>
</tr>
<tr >
	<th>Expire date<br />(yyyy-mm-dd)</th>
	<td><input name="expire_date" id="expire_date" type="text" size="30" value="{{item.expire_date}}" ></td>
</tr>

<tr >
	<th>Status</th>
	<td >
		<select name="status" id="status">
			<option value="0">New</option>
			<option value="1">Approve</option>
			<option value="2">Cancel</option>
		</select>
 	</td>
</tr>
</table>
<br><br>
<input type="submit" value="Update">
<br><br>
</form>
{%endblock%}